//
// Bonus5Part.hh for nibbler in /home/lefebv_w//workspace/cpp/nibbler/googleCode
// 
// Made by damien lefebvre
// Login   <lefebv_w@epitech.net>
// 
// Started on  Thu Mar 21 14:20:12 2013 damien lefebvre
// Last update Sun Mar 24 18:44:11 2013 damien lefebvre
//

#ifndef		__BONUS5PART_HH__
#define		__BONUS5PART_HH__

#include	<vector>
#include	<string>
#include	<iostream>
#include	<stdlib.h>

#include	"header.hh"
#include	"IGraphicLibrary.hh"
#include	"Case.hh"
#include	"Snake.hh"
#include	"IBonus.hh"

class		Bonus5Part : public IBonus
{
private :
  IGraphicLibrary::e_TypeOfCase		m_type;
  unsigned int				m_pos_x;
  unsigned int				m_pos_y;
  IGraphicLibrary::e_ListOfImage	m_img;
  t_frame				m_lastmove;
  t_frame				m_timer;
  t_frame	       			m_timeToCatch;
  t_frame				m_framerate;

public :
  Bonus5Part();

  virtual void		generatePosition(t_frame frame, std::vector< std::vector<Case *> > const & map, Snake const & snake);
  virtual void		draw(t_frame frame, IGraphicLibrary & graph) const;
  virtual bool		checkSnakePosition(t_frame frame, Snake const & snake) const;
  virtual void		move(t_frame frame, std::vector< std::vector<Case *> > const & map, Snake const & snake);
  virtual t_frame	getLastMove(void) const;
  virtual t_frame      	getFrameRate(void) const;
};

#endif
